package com.swxy.club.dto;



import com.baomidou.mybatisplus.annotation.*;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.swxy.club.dto.BaseDto;
import com.swxy.club.enums.AuditStatus;
import com.swxy.club.enums.ClubStatus;
import com.swxy.club.serializer.EnumFlatSerializer;
import lombok.Data;
import lombok.EqualsAndHashCode;


/**
 * 社团实体类
 * 对应数据库表 culb
 */
@Data
@EqualsAndHashCode(callSuper = true)
@TableName("culb")
public class Club extends BaseDto {

    /**
     * 社团ID，主键自增
     */
    @TableId(value = "culb_id", type = IdType.AUTO)
    private Long clubId;

    /**
     * 社团分类ID
     */
    @TableField("category_id")
    private Long categoryId;

    /**
     * 社团名称
     */
    @TableField("name")
    private String name;

    /**
     * 社团描述
     */
    @TableField("description")
    private String description;

    /**
     * 社团成员数量
     */
    @TableField("member_count")
    private Integer memberCount = 0;

    /**
     * 社团状态
     */
    @TableField("status")
    @JsonSerialize(using = EnumFlatSerializer.class)
    private ClubStatus status;

    /**
     * 审核状态
     */
    @TableField("appli_status")
    @JsonSerialize(using = EnumFlatSerializer.class)
    private AuditStatus appliStatus;
}
